﻿@model IEnumerable<System.Data.DataRow>
@using System.Data;

@{

    var questionnaire = (Questionnaire)ViewBag.questionnaire;
    var result2 = (DataTable)ViewBag.result2;
    var result3 = (DataTable)ViewBag.result3;

    ViewBag.Title = questionnaire.QuestionnaireName;
    ViewBag.Source = questionnaire.Source;
}

<h2>
    <div class="divTitle">
        @questionnaire.QuestionnaireName
    </div>
</h2>

<table class="table">
    <tr>
        <th>
            省
        </th>
        <th>
            市
        </th>
        <th>
            答卷数量
        </th>
        <th style="display:none">
           问卷管理
        </th>
        <th style="display:none">
            导出Excel
        </th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item["Province"])
        </td>
        <td>
            @Html.DisplayFor(modelItem => item["City"])
        </td>
        <td>
            @item["Cc"]
        </td>
        <td style="display:none">
            @Html.ActionLink("后台管理", "Index2", new { id= questionnaire.ID, Province = @item["Province"] , City= @item["City"] }, new { target = "_blank" })
        </td>
        <td style="display:none">
            @Html.ActionLink("导出", "Excel", new { id = questionnaire.ID, Province = @item["Province"], City = @item["City"] }, new { target = "_blank" })
        </td>
    </tr>
}

</table>



<table class="table">
    <tr>
        <th>
            省
        </th>
        <th>
            市
        </th>
        <th>
            医院等级
        </th>
        <th>
            答卷数量
        </th>
    </tr>

    @foreach (DataRow item in result2.Rows)
    {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item["Province"])
            </td>
            <td>
                @Html.DisplayFor(modelItem => item["City"])
            </td>
            <td>
                @Html.DisplayFor(modelItem => item["HospitalLevel"])
            </td>
            <td>
                @item["Cc"]
            </td>
        </tr>
    }

</table>

<table class="table">
    <tr>
        <th>
            省
        </th>
        <th>
            医院等级
        </th>
        <th>
            答卷数量
        </th>
    </tr>

@foreach (DataRow item in result3.Rows)
{
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item["Province"])
            </td>
            <td>
                @Html.DisplayFor(modelItem => item["HospitalLevel"])
            </td>
            <td>
                @item["Cc"]
            </td>
        </tr>
    }

</table>